package com.stx.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.stx.dao.TeacherDao;
import com.stx.domain.Teacher;
import com.stx.service.TeacherService;

@Service
public class TeacherServiceImpl implements TeacherService {
	@Resource
	private TeacherDao td;
	
	public Teacher teacherLogin(int no,String pwd) {
		return td.teacherLogin(no, pwd);
	}

	public int modifyPasswordByT(int no,String newpassword){
		return td.modifyPasswordByT(no, newpassword);	
	}

	@Override
	public List<Teacher> selectTeacher() {
		return td.selectTeacher();
	}

	@Override
	public void updateTeacher(Teacher teacher) {
		td.updateTeacher(teacher);
	}

	@Override
	public void teacherDelete(int no) {
		td.teacherDelete(no);
	}

	@Override
	public int addTeacher(Teacher teacher) {
		return td.addTeacher(teacher);
	}
	
}
